{include file="public/header" /}
<body>
	<div class="container text-center">
		<div class="row clearfix">
			<div class="col-md-12 column">
				<img src="https://img.php.cn/upload/avatar/000/000/001/5e8938fc8a7db289.png" />
			</div>
		</div>
	</div>
	<div class="container">
		<div class="row clearfix">
			<div class="col-md-12 column">
				<div class="form-group">
					<label for="phone">手机号</label>
					<input type="number" class="form-control" id="phone" placeholder="请输入11位手机号"/>
				</div>
				<div class="form-group">
					<label for="pwd">密码</label>
					<input type="password" class="form-control" id="pwd" placeholder="请输入6-12位密码"/>
				</div>
				<button type="submit" class="btn btn-success btn-block" id="login">登录</button>
			</div>
		</div>
		<div class="clearfix" style="margin-top:15px;">
			<a href="reg" class="btn btn-default btn-link pull-right">注册</a>
		</div>
	</div>
	<script type="text/javascript">
		$("#login").click(function(){
			var phone = $("#phone").val();
			var pwd = $("#pwd").val();
			$.post("/index.php/index/index/login_json",{phone:phone,pwd:pwd},function(res){
				if(res.code != 0){
					alert(res.msg);
					return false;
				}
				alert('登录成功');
				window.location.href = '/index.php/index/index/index';
			},'json');
		})
	</script>
{include file="public/tail" /}